#coding:utf-8
from flask import Flask
from flask_sqlalchemy import SQLAlchemy


app = Flask(__name__)

app.debug = True
app.secret_key = '\xf6\x81W\xea\xd7i\xd2\x99\x11\x97'
db = SQLAlchemy(app)

def create_app():
    app.config['SQLALCHEMY_DATABASE_URI'] = 'mysql://root:123@127.0.0.1:3306/videos'
    from .main import main
    app.register_blueprint(main)


    from .auth import auth
    app.register_blueprint(auth)
    
    return app